<%@ taglib prefix="shiro" uri="http://shiro.apache.org/tags" %>
<%@ page contentType="text/html;charset=UTF-8" language="java" %>
<!DOCTYPE html>
<html>
<head>
	<title>部门管理</title>
	<jsp:include page="../comm/header.jsp"/>
	<link rel="stylesheet" type="text/css" href="deptment.css">
</head>
<body>
	<input id="txtRootPath" type="hidden" value="<%=request.getContextPath()%>"/>

	<%--toolbar--%>
	<nav class="navbar navbar-default" id="toolbar">
		<div class="container-fluid">
			<shiro:hasPermission name="Y01:1">
				<button id="btnAdd" class="navbar-btn btn btn-default" onclick="addPost()"><i class="iconfont icon-xinzeng-copy"></i> 新增</button>
			</shiro:hasPermission>
			<shiro:hasPermission name="Y01:2">
				<button id="btnEdit" class="navbar-btn btn btn-default" onclick="editPost()"><i class="iconfont icon-modify"></i> 修改</button>
			</shiro:hasPermission>
			<shiro:hasPermission name="Y01:4">
				<button id="btnDel" class="navbar-btn btn btn-default" onclick="delPost()"><i class="iconfont icon-shanchu"></i> 删除</button>
			</shiro:hasPermission>
			<button id="btnrefresh" class="navbar-btn btn btn-default" onclick="onRefresh()"><i class="iconfont icon-chaxun"></i> 刷新</button>
			<button id="btnPrint" class="navbar-btn btn btn-default" onclick="printPost()"><i class="iconfont icon-iconfontdayin"></i> 打印</button>
			<button id="btnExport" class="navbar-btn btn btn-default" onclick="exportPost()"><i class="iconfont icon-export"></i> 导出</button>
			<button id="btnClose" class="navbar-btn btn btn-default" onclick="exitFrame()"><i class="iconfont icon-tuichu"></i> 退出</button>
		</div>
	</nav>

	<%--table--%>
	<table id="department-table"></table>

	<%--弹出窗口--%>
	<div id="add-content" style="display: none">
		<form class="form-horizontal" style="padding-top: 10px">
			<div class="form-group">
				<label for="department-code" class="col-xs-2 control-label">部门代码:</label>
				<div class="col-xs-8">
					<input type="text" class="form-control" id="department-code" name="department-code" placeholder="部门代码">
				</div>
				<div class="col-xs-2">
					<div class="checkbox">
						<label>
							<input type="checkbox" id="FISSTOP" name="FISSTOP"> 停用
						</label>
					</div>
				</div>
			</div>
			<div class="form-group">
				<label for="department-name" class="col-xs-2 control-label">部门名称:</label>
				<div class="col-xs-10">
					<input type="text" class="form-control" id="department-name" name="department-name" placeholder="部门名称">
				</div>
			</div>
			<div class="form-group">
				<label for="parent-department" class="col-xs-2 control-label">所属机关:</label>
				<div class="col-xs-10">
					<input type="text" class="form-control" id="parent-department" name="parent-department" style="cursor: pointer" placeholder="所属机关" onclick="chooseParent()" readonly>
				</div>
			</div>
			<div class="form-group">
				<label for="FSHORTNAME" class="col-xs-2 control-label">简称:</label>
				<div class="col-xs-3">
					<input type="text" class="form-control" id="FSHORTNAME" name="FSHORTNAME" placeholder="简称" >
				</div>
				<label for="FDEPTLEVEL" class="col-xs-2 col-xs-offset-2 control-label">机构级次:</label>
				<div class="col-xs-3">
					<select class="form-control" id="FDEPTLEVEL" name="FDEPTLEVEL">
						<option value="0">税务部门</option>
						<option value="1">总局</option>
						<option value="2" selected="selected">省局</option>
						<option value="3">地市局</option>
						<option value="4">区县局</option>
					</select>
				</div>
			</div>
			<div class="form-group">
				<label for="FTRANCODE" class="col-xs-2 control-label">对应码</label>
				<div class="col-xs-10">
					<input type="text" class="form-control" id="FTRANCODE" name="FTRANCODE" placeholder="对应码">
				</div>
			</div>
		</form>
	</div>

	<jsp:include page="../comm/footer.jsp"/>
	<script type="text/javascript" src="deptment.js"></script>
</body>

